package com.bajiao.mapper.store;

import com.bajiao.dto.store.StoreDetailsRequest;
import com.bajiao.dto.store.StoreRequest;
import com.bajiao.entity.store.Store;
import com.bajiao.vo.store.*;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

/**
 * @Description: 店铺表
 * @Author: FanJq
 * @Date:   2024-12-12
 * @Version: V1.0
 */
public interface StoreMapper extends BaseMapper<Store> {

    /**
     * @Description
     * 获取店铺列表
     * @date 2024/12/12 17:32
     * @author FanJq
     * @param request
     * @return {@link List< StoreResponse>}
    */
    List<StoreResponse> getStoreList(StoreRequest request);

    /**
     * @Description
     * 获取店铺详情
     * @date 2024/12/13 10:14
     * @author FanJq
     * @param request
     * @return {@link StoreDetailsResponse}
    */
    StoreDetailsResponse getStoreDetails(StoreDetailsRequest request);

    /**
     * @Description
     * 今日核销面额
     * @date 2024/12/27 14:49
     * @author FanJq
     * @param storeId
     * @return {@link BigDecimal}
    */
    BigDecimal getTodayAmount(@Param("storeId") String storeId);

    /**
     * @Description
     * 今日核销券数量
     * @date 2024/12/27 14:52
     * @author FanJq
     * @param storeId
     * @return {@link Long}
    */
    Long getTodayNum(@Param("storeId") String storeId);

    /**
     * @Description
     * 昨日核销面额
     * @date 2024/12/27 14:53
     * @author FanJq
     * @param storeId
     * @return {@link BigDecimal}
    */
    BigDecimal getYesterdayAmount(@Param("storeId") String storeId);

    /**
     * @Description
     * 昨日核销券数量
     * @date 2024/12/27 14:55
     * @author FanJq
     * @param storeId
     * @return {@link Long}
    */
    Long getYesterdayNum(@Param("storeId") String storeId);

    /**
     * @Description
     * 近七天营业额
     * @date 2024/12/27 15:00
     * @author FanJq
     * @param storeId
     * @return {@link List< StoreRecentDays>}
    */
    List<StoreRecentDays> getRecentDaysList(@Param("storeId") String storeId);

    /**
     * @Description
     * 本月核销面额
     * @date 2024/12/27 14:49
     * @author FanJq
     * @param storeId
     * @return {@link BigDecimal}
     */
    BigDecimal getThisMonthAmount(@Param("storeId") String storeId);

    /**
     * @Description
     * 本月核销券数量
     * @date 2024/12/27 14:52
     * @author FanJq
     * @param storeId
     * @return {@link Long}
     */
    Long getThisMonthNum(@Param("storeId") String storeId);

    /**
     * @Description
     * 上月核销面额
     * @date 2024/12/27 14:53
     * @author FanJq
     * @param storeId
     * @return {@link BigDecimal}
     */
    BigDecimal getLastMonthAmount(@Param("storeId") String storeId);

    /**
     * @Description
     * 上月核销券数量
     * @date 2024/12/27 14:55
     * @author FanJq
     * @param storeId
     * @return {@link Long}
     */
    Long getLastMonthNum(@Param("storeId") String storeId);

    /**
     * @Description
     * 总核销面额
     * @date 2024/12/27 15:09
     * @author FanJq
     * @param storeId
     * @return {@link BigDecimal}
    */
    BigDecimal getTotalAmount(@Param("storeId") String storeId);

    /**
     * @Description
     * 总核销券数量
     * @date 2024/12/27 15:09
     * @author FanJq
     * @param storeId
     * @return {@link Long}
    */
    Long getTotalNum(@Param("storeId") String storeId);

    /**
     * @Description
     * 门店商品订单
     * @date 2024/12/28 10:46
     * @author FanJq
     * @param storeId
     * @return {@link List< StoreOrderResponse>}
    */
    List<StoreOrderResponse> getStoreOrderPage(@Param("storeId") String storeId);

    /**
     * @Description
     * 门店优惠券订单
     * @date 2024/12/28 10:49
     * @author FanJq
     * @param storeId
     * @return {@link List< StoreCouponOrderResponse>}
    */
    List<StoreCouponOrderResponse> getStoreCouponOrderPage(@Param("storeId") String storeId);

    /**
     * @Description
     * 管理后台列表
     * @date 2025/1/3 16:46
     * @author FanJq
     * @param account
     * @param title
     * @param mobile
     * @return {@link List< StoreAdmin>}
    */
    List<StoreAdmin> getAdminList(String account, String title, String mobile);

    /**
     * @Description
     * 店铺统计列表
     * @date 2025/1/9 17:52
     * @author FanJq
     * @param title
     * @return {@link List< StoreStatistics>}
    */
    List<StoreStatistics> getStatisticsList(String title);

    /**
     * @Description
     * 店铺核销记录
     * @date 2025/1/9 18:07
     * @author FanJq
     * @param keywords
     * @param orderNo
     * @param storeTitle
     * @param title
     * @param createTimeBegin
     * @param createTimeEnd
     * @return {@link List< StoreVerify>}
    */
    List<StoreVerify> getVerifyList(String keywords, String orderNo, String storeTitle, String title, String createTimeBegin, String createTimeEnd);
}

